package com.atguigu.java;

import java.util.ArrayList;
import java.util.List;

/**
 * ClassName: GCTest
 * Description:
 * Date: 2021/2/24 20:45
 * Company: TravelSky
 *
 * @author YangXin
 */
public class GCTest {

    public static void main(String[] args) {
        int i = 0;
        try {
            List<String> list = new ArrayList<String>();
            String a = "yangxin";
            while (true){
                list.add(a);
                i++;
            }
        }catch (Throwable e){
            e.printStackTrace();
            System.out.println("遍历次数为： "+ i);
        }
    }
}
